package acwing;

import java.awt.*;
import java.io.*;
import java.util.*;

public class ac4309 {
    static StreamTokenizer in = new StreamTokenizer(new BufferedReader(new InputStreamReader(System.in)));
    static PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out));
    static BufferedReader bin = new BufferedReader(new InputStreamReader(System.in));
    static Set<Point> res = new HashSet<>();

    static int cin() throws IOException {
        in.nextToken();
        return (int) in.nval;
    }

    static int gcd(int a, int b) {
        return b != 0 ? gcd(b, a % b) : a;
    }

    public static void main(String[] args) throws IOException {
        int n, x0, y0;
        n = cin(); x0 = cin(); y0 = cin();
        while (n -- > 0) {
            int sx, sy;
            sx = cin(); sy = cin();
            int k1 = sx - x0, k2 = sy - y0;
            int mn = gcd(k1, k2);
            res.add(new Point(k1 / mn, k2 / mn));
        }
        out.println(res.size());
        out.close();
//        Set<PII> set = new HashSet<>();
//        set.add(new PII(1, 2));
//        set.add(new PII(1, 2));
//        System.out.println(set);
//        Set<Point> set1 = new HashSet<>();
//        set1.add(new Point(1, 2));
//        set1.add(new Point(1, 2));
//        System.out.println(set1);
    }
}
//class PII{
//    int a, b;
//
//    public PII(int a, int b) {
//        this.a = a;
//        this.b = b;
//    }
//
//    @Override
//    public boolean equals(Object o) {
//        if (this == o) return true;
//        if (o == null || getClass() != o.getClass()) return false;
//        PII pii = (PII) o;
//        return a == pii.a && b == pii.b;
//    }
//
//    @Override
//    public int hashCode() {
//        return Objects.hash(a, b);
//    }
//
//    @Override
//    public String toString() {
//        return "PII{" +
//                "a=" + a +
//                ", b=" + b +
//                '}';
//    }
//}
